import Vue from 'vue'
import App from './App.vue'
import Router from 'vue-router'
import myRouter from "./router/router.js";
import axios from "axios"; // 引入请求的axios
const router = new Router(myRouter)
Vue.use(Router);
// Vue原型上绑定url
Vue.prototype.myUrl = 'http://aircommunity.net/api/v2/'; //绑定url
Vue.prototype.$http = axios // 将vue原型上的请求换成axios
Vue.filter('myPrice', function (oldValue) {
  oldValue = Number(oldValue);
  if (oldValue == 0) {
    oldValue = 200;
    return oldValue;
  }
})
new Vue({
  el: '#app',
  render: h => h(App),
  router,
  template: '<App/>',
  components: { App }
}).$mount('#app')
